import { getAddress} from "@/services";

const state = {
  addressList: [],
};

const mutations = {
    getAddressS(state, payload) {
      console.log(payload);
    state.addressList = payload.res;

  },
};

const actions = {
  
  async getAddress({ commit }) {
    let res = await getAddress();
    // console.log(res, "res---------------*");
    commit("getAddressS", {res });
  },
};

export default {
  namespaced: true,
  actions,
  mutations,
  state,
};
